﻿SELECT 
	(SELECT COUNT(*) FROM NHFStart.Store) AS Store,
	(SELECT COUNT(*) FROM NHFStart.Product) AS Product,
	(SELECT COUNT(*) FROM NHFStart.StoreProduct) AS StoreProduct,
	(SELECT COUNT(*) FROM NHFStart.Employee) AS Employee
GO

SELECT s.Name AS Store, p.Name AS Product
FROM NHFStart.Store AS s
INNER JOIN NHFStart.StoreProduct AS sp On sp.StoreId = s.Id 
INNER JOIN NHFStart.Product AS p On p.Id = sp.ProductId 
GO

SELECT s.Name AS Store, e.FirstName + E.LastName AS Employee
FROM NHFStart.Store AS s
INNER JOIN NHFStart.Employee AS e On E.StoreId = S.Id 
GO

SELECT * FROM NHFStart.Store
GO
SELECT * FROM NHFStart.Product
GO
SELECT * FROM NHFStart.StoreProduct 
GO
SELECT * FROM NHFStart.Employee
GO

TRUNCATE TABLE NHFStart.Employee
GO
TRUNCATE TABLE NHFStart.StoreProduct
GO
DELETE FROM NHFStart.Store
GO
DELETE FROM NHFStart.Product
GO
